package edu.hcnu.mapper;

import edu.hcnu.po.SheBei;
import org.apache.ibatis.annotations.*;

import java.util.List;

@Mapper
public interface SheBeiMapper {

    @Select("select * from shebei ")
    List<SheBei> list();

    @Select("select * from shebei where id=#{id}")
    SheBei queryByID(String id);

    @Insert("insert into shebei(id, name, label) VALUES (#{id},#{name},#{label})")
    boolean insert(SheBei sheBei)  ;

    @Update("update shebei set name=#{name},label=#{label} where id=#{id}")
    boolean update(SheBei sheBei);

    @Delete("delete from shebei where id=#{id}")
   boolean delete(String id);


}
